class Shape {
  getArea() {

  }
}

class Rectangle extends Shape {
  getArea() {
    return 100
  }
}

class Circle extends Shape {
  getArea() {
    return 200
  }
}

var r = new Rectangle()
var c = new Circle()

function computeArea(shape: Shape) {
  console.log(shape.getArea())
}

computeArea(r)
computeArea(c)
